package com.ruoyi.web.controller.app;

import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.wb.service.IWbContractService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * 维保合同Controller
 *
 * @author ruoyi
 * @date 2024-10-14
 */

@Api(tags="app端-维保合同管理")
@RestController
@RequestMapping("/wb/app/wbContract")
public class WbAppContractController extends BaseController {

    @Autowired
    private IWbContractService wbContractService;

    @ApiOperation("查询合同信息包含维修记录(客户id是企业的id)")
    @GetMapping(value = "getContractInfoByClientId/{clientId}")
    public AjaxResult getContractInfoByClientId(@PathVariable("clientId") Long clientId) {
        return success(wbContractService.getContractInfoByClientId(clientId));
    }

}